<!DOCTYPE html>
<html>
    <head>
   <meta charset="UTF-8">
   <title>输入文本</title>
   <style type="text/css">
    *{padding:0px;margin: 0px;}
   
   /* .warp{    
              height:400px;
              width: 100%;
              border:1px blue solid;              
              line-height: 400px;
              text-align: center;   
             }
*/
     




     .warp{
              height:400px;
              width: 100%;
              border:1px blue solid;              
              display:table;      
             }

     .content{
              text-align: center;             
              display:table-cell;
              vertical-align:middle;              
              }



   </style>
</head>
<body>
 <div class="warp">
        <div class="content">
            <img src="img\logo.jpg"/>
            <h1>Welcome to Website</h1>
            <h2>CSS层叠样式，用于网页样式设置，使网页更美观。</h2>
        </div>

<!-- <div class="warp">
      <p>Welcome to Website<br>
      CSS层叠样式，用于网页样式设置，使网页更美观。</p>
</div> -->        
</div>
</body>
</html>